/*********************************************************
*
*  FJH-sim v1.0
*  Copyright � 2008 J.H. Donker, J. Teeuw
*
*  Simulator stress-testing driver
*
**********************************************************/

#pragma once
#include "Simulator.h"

class StressDriver: public simulator::Driver
{
public:
	void createWorld();
	void sendDrive();
	void receiveDrive();
	void waitForContinue();
	StressDriver(int nodes, int world);
	
	void addEventToSimulator(simulator::Event* e);
	void recieveEventAtNode(simulator::Event* e);
	
	void run(int runs);
	
	void printStat();
private:
	int nrNodes;
	int worldType;
public:
	unsigned int packetsSent;
	unsigned int packetsRecieved;
	
	unsigned int routingPacketSent;
	unsigned int ackPackeSent;
	unsigned int segPacketSent;
	
	unsigned int routingPacketReceived;
	unsigned int ackPacketReceived;
	unsigned int segPacketReceived;
	
	unsigned int messagesSent;
	unsigned int messagesReceived;
};

